package com.wzy.vx.service;

import com.wzy.vx.DTO.CateDTO;
import com.wzy.vx.dataobject.ProductInfo;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import java.util.List;

/**
 * @ProjectName: vx
 * @Package: com.wzy.vx.service
 * @ClassName: ProductService
 * @Author: Administrator
 * @Description: ${description}
 * @Date: 2019/3/12 13:50
 * @Version: 1.0
 */
public interface ProductService {
    ProductInfo findOne(String productId);

    List<ProductInfo> findUpAll();

    Page<ProductInfo> findAll(Pageable pageable);

    ProductInfo save(ProductInfo productInfo);

    //t加库存
    void increaseStock(List<CateDTO> cateDTOList);
    //减库存
    void descStock(List<CateDTO> cateDTOList);

    //上架
    ProductInfo onSale(String productId);
    //下架
    ProductInfo offSale(String productId);
}
